package com.punai.customer.domain;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import com.punai.common.annotation.Excel;
import com.punai.common.core.domain.BaseEntity;
import com.punai.common.core.domain.TreeParentBo;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

/**
 * 机械章节对象 cus_mechanical_chapter
 *
 * @author zxw
 * @date 2022-12-04
 */
public class CusMechanicalChapter extends BaseEntity  implements TreeParentBo {
    private static final long serialVersionUID = 1L;

    /**
     * $column.columnComment
     */
    private String id;

    /**
     * 公司id
     */
    private Long companyId;

    /**
     * 章节名称
     */
    @Excel(name = "章节名称")
    private String chapterName;

    /**
     * 父节点id
     */
    @Excel(name = "父节点id")
    private String pid;

    /**
     * 族谱id
     */
    @Excel(name = "族谱id")
    private String pids;

    /**
     * 层级编码
     */
    @Excel(name = "层级编码")
    private String code;

    /**
     * 部门id
     */
    @Excel(name = "部门id")
    @TableField(fill = FieldFill.INSERT)
    private Long deptId;

    /**
     * 用户id
     */
    @Excel(name = "用户id")
    @TableField(fill = FieldFill.INSERT)
    private Long userId;

    /**
     * 排序
     */
    @Excel(name = "排序")
    private Integer orderNum;

    public void setId(String id) {
        this.id = id;
    }

    public String getId() {
        return id;
    }

    public void setCompanyId(Long companyId) {
        this.companyId = companyId;
    }

    public Long getCompanyId() {
        return companyId;
    }

    public void setChapterName(String chapterName) {
        this.chapterName = chapterName;
    }

    public String getChapterName() {
        return chapterName;
    }

    public void setPid(String pid) {
        this.pid = pid;
    }

    public String getPid() {
        return pid;
    }

    @Override
    public String getName() {
        return chapterName;
    }

    @Override
    public String getVersionsId() {
        return null;
    }

    public void setPids(String pids) {
        this.pids = pids;
    }

    public String getPids() {
        return pids;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getCode() {
        return code;
    }

    public void setDeptId(Long deptId) {
        this.deptId = deptId;
    }

    public Long getDeptId() {
        return deptId;
    }

    public void setUserId(Long userId) {
        this.userId = userId;
    }

    public Long getUserId() {
        return userId;
    }

    public void setOrderNum(Integer orderNum) {
        this.orderNum = orderNum;
    }

    public Integer getOrderNum() {
        return orderNum;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("companyId", getCompanyId())
                .append("chapterName", getChapterName())
                .append("pid", getPid())
                .append("pids", getPids())
                .append("code", getCode())
                .append("deptId", getDeptId())
                .append("userId", getUserId())
                .append("orderNum", getOrderNum())
                .append("createTime", getCreateTime())
                .append("createBy", getCreateBy())
                .append("updateTime", getUpdateTime())
                .append("updateBy", getUpdateBy())
                .toString();
    }
}
